package mobilesearch.data;

import android.os.Parcel;
import android.os.Parcelable;
import android.util.Log;

public class ContactsData implements Parcelable {
	
	private static final String TAG = "ContactsData";

	private String contactId;
	private String displayName;
	private String phoneNumber;

	public ContactsData() {
		Log.i(TAG, "ContactsData()");
	}

	private ContactsData(Parcel in){
		Log.i(TAG, "ContactsData(Parcel in)");
		
		this.contactId = in.readString();
		this.displayName = in.readString();
		this.phoneNumber = in.readString();
	}
	
	@Override
	public int describeContents() {
		return 0;
	}

	@Override
	public void writeToParcel(Parcel dest, int flags) {
		dest.writeString(this.contactId);
		dest.writeString(this.displayName);
		dest.writeString(this.phoneNumber);
	}
	
	public static final Parcelable.Creator<ContactsData> CREATOR =new Parcelable.Creator<ContactsData>() {

		@Override
		public ContactsData createFromParcel(Parcel source) {
			return new ContactsData(source);
		}

		@Override
		public ContactsData[] newArray(int size) {
			return new ContactsData[size];
		}
	};

	
	public String getContactId() {
		return contactId;
	}

	public void setContactId(String contactId) {
		this.contactId = contactId;
	}

	public String getDisplayName() {
		return displayName;
	}

	public void setDisplayName(String displayName) {
		this.displayName = displayName;
	}

	public String getPhoneNumber() {
		return phoneNumber;
	}

	public void setPhoneNumber(String phoneNumber) {
		this.phoneNumber = phoneNumber;
	}

}
